<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@include file="../jsp/commons/taglibs.jsp"%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>

<title>找回密码</title>

<%@include file="../jsp/commons/meta.jsp"%>
<!-- <meta http-equiv="pragma" content="no-cache">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="expires" content="0">
<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
<meta http-equiv="description" content="This is my page"> -->

<link href="http://libs.baidu.com/bootstrap/3.0.3/css/bootstrap.min.css"
	rel="stylesheet">
<script src="http://libs.baidu.com/jquery/2.0.0/jquery.min.js"></script>
<script src="http://libs.baidu.com/bootstrap/3.0.3/js/bootstrap.min.js"></script>
<script src="${ctx }/javascript/md5.js"></script>

<style type="text/css">
#big {
	width: auto;
	height: auto;
}
</style>

</head>

<body style="font-family:'楷体'; font-size: 24px;background: #DADADA;">
	<div id="big" align="center">
		<div class="container-fluid"
			style="background-color:#438EB8;height: 40px; width: auto;">
			<div
				style="font-size:22px;color:#ffffff; padding-top:5px; width: auto;height: auto;">
				<span>用户找回密码</span>
			</div>
		</div>
		<form class="form-horizontal" action="${ctx }/wumimember/memberaction!sendSms"
			method="post" role="from" id="form1" name="form1">
			<table width="240" height="230" border="0"
				style="text-align:center;margin-top: 50px;">
				<tr>
					<td height="60"><label style="font-size: 20px;">请输入您的手机号</label>
					</td>

				</tr>
				<tr>
					<td width="234" height="58" style="text-align: center;">
						<div class="col-sm-10" style="margin-left: 20px;">
							<input type="text" class="form-control" id="mobile" name="mobile"
								placeholder="请输入手机号" onblur="checkMobile()">
						</div></td>
				</tr>
				<tr>
					<td height="44">
						<div id="MobileMessage">${message }</div>
					</td>
				</tr>

				<tr>
					<td height="58"><button type="button" class="btn btn-primary" onclick="OnSubmit()">提交</button>
					</td>
				</tr>
			</table>
		</form>
		<div style="width: auto;height: auto;margin-top: 200px;">
			<c:import url="/jsp/commons/footer.jsp"></c:import>
		</div>
	</div>
</body>

<script type="text/javascript">
	function checkMobile() {
		var Mobile = $("#mobile").val();
		if (Mobile.length == 0) {
			$("#MobileMessage").html("<font color='red'>手机号不能为空</font>");
			return false;
		} else {
			$("#MobileMessage").html("");
			return true;
		}
	}

	function OnSubmit() {
		var Mobile = $("#mobile").val();
		var regStr = /^(130|131|132|133|134|135|136|137|138|139|159|158|153|152|188|186|147|155|189)(\d){8}$/;
		if (Mobile.length == 0) {
			$("#MobileMessage").html("<font color='red'>手机号不能为空</font>");
		} else {
			if (!regStr.test(Mobile)) {
				$("#MobileMessage").html("<font color='red'>手机号不合法</font>");
			} else {
				$("#MobileMessage").html("");
				form1.submit();
			}
		}
	}
</script>
</html>